home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Tech Arsenal 1
/
Tech Arsenal (Arsenal Computer).ISO
/
tek-03
/
qbasicpg.zip
/
BANZAI.BAS
< prev
next >
Wrap
BASIC Source File
|
1989-08-31
|
709b
|
29 lines
' BANZAI.BAS
' This program uses a one-dimensional dynamic string array to store names
' of characters from the movie "The Adventures of Buckaroo Banzai."
OPTION BASE 1 ' set array base at 1
CLS
PRINT "** This program collects character names from the film ";
PRINT "'Buckaroo Banzai' **"
PRINT
INPUT "How many names would you like to enter? ", names%
DIM characters$(names%) ' dimension array
PRINT ' fill dynamic array
FOR i% = 1 TO names%
INPUT " Name: ", characters$(i%)
NEXT i%
PRINT
PRINT "You entered the following names:"
PRINT
FOR i% = 1 TO names% ' print contents of array
PRINT characters$(i%)
NEXT i%